<?php
	class User extends AppModel
	{
		var $name = 'User';
		var $primaryKey = 'username';
		
		var $belongsTo = array('Dependency' =>
							array('className' => 'Dependency',
								  'foreignKey' => 'id_dependencia',
  								  'conditions' => '',
								  'fields' => 'nombre',
								  'order' => ''
								),
							);
		
		var $validate = array(  'username' => VALID_NOT_EMPTY ,
								'password' => VALID_NOT_EMPTY ,
								'tipo_usuario' => VALID_NUMBER ,
								'dependencia' => VALID_NUMBER  );
		

	}
?>